package com.nmsl.nurse.controller;

import com.nmsl.nurse.domain.MEmployee;
import com.nmsl.nurse.service.IMEmployeeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/Memployee")
public class MEmployeeController {
    @Autowired
    private IMEmployeeService employeeService;
    @RequestMapping("/selectEmployeeByEmployeeId")
    public MEmployee selectEmployeeByEmployeeId(Long employeeId){
        return employeeService.selectEmployeeByEmployeeId(employeeId);
    }
    @GetMapping("/selectall")
    public List<MEmployee> selectall(){
        return employeeService.selectall();
    }
}
